﻿
cmake_minimum_required(VERSION 3.12...3.15 FATAL_ERROR)

set(_project galois)
project (${_project})

set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${CMAKE_CURRENT_SOURCE_DIR}/CMake)

#include(Utilities/Git/Git.cmake)
include(VTKmDetermineVersion)

# Load hardcoded version in case this is not a Git repository
file(STRINGS version.txt version_txt)
extract_version_components("${version_txt}" "VTKm")
# Get the version from git if we can
#determine_version(${VTKm_SOURCE_DIR} ${GIT_EXECUTABLE} "VTKm")

if (NOT DEFINED VTKm_INSTALL_INCLUDE_DIR)
  set(VTKm_INSTALL_INCLUDE_DIR "include/vtkm-${VTKm_VERSION_MAJOR}.${VTKm_VERSION_MINOR}")
endif()

#include(VTKmCompilerFlags)
#include(VTKmWrappers)

add_library(compiler_flags INTERFACE)
target_include_directories(compiler_flags INTERFACE
  $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>
  #$<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}/include>
  #$<INSTALL_INTERFACE:${VTKm_INSTALL_INCLUDE_DIR}>
  )

option(enable_example "开启example" FALSE})

# 框架核心
add_subdirectory(galois)

# 第三方库
add_subdirectory(contrib)

# 例子
add_subdirectory(examples)

